Appendix 2: Essential Vim Shortcuts for Text Editing
Movement Commands
h j k l
- Move left, down, up, right
w
- Jump to next word
b
- Jump to previous word
0
- Go to beginning of line
$
- Go to end of line
Editing Commands
dd
- Delete entire line
dw
- Delete word
p
- Paste after cursor
P
- Paste before cursor
u
- Undo
Ctrl+r
- Redo
Clipboard Integration
:%y+
- Copy entire buffer to system clipboard
:%w !pbcopy
- Write buffer to clipboard (macOS)
:r !pbpaste
- Read from clipboard into buffer